﻿<!--
Author : K.F.Storm
Email : yk000123 at sina.com
Website : http://www.kfstorm.com	
-->
<local:ChildWindowBase x:Class="DoubanFM.UISettingWindow"
		xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
		xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
		xmlns:local="clr-namespace:DoubanFM"
        xmlns:resx="clr-namespace:DoubanFM.Resources"
		x:Name="Window"
		Title="{x:Static resx:Resources.InterfaceSettingsButton}" Background="#FF813131" Foreground="White">
	<Grid Width="300" Margin="10">
		<StackPanel>
            <CheckBox Margin="0,2" VerticalAlignment="Center" IsChecked="{Binding Settings.ShowBalloonWhenSongChanged, Mode=TwoWay, Source={StaticResource Player}}" Content="{x:Static resx:Resources.UISettingsWindowPopupCb}"/>
            <CheckBox Margin="0,2" x:Name="CheckBoxTopMost" VerticalAlignment="Center" IsChecked="{Binding Settings.TopMost, Mode=TwoWay, Source={StaticResource Player}}" Content="{x:Static resx:Resources.CheckBoxTopMost}"/>
            <CheckBox Margin="0,2" x:Name="CheckBoxAlwaysShowNotifyIcon" VerticalAlignment="Center" IsChecked="{Binding Settings.AlwaysShowNotifyIcon, Mode=TwoWay, Source={StaticResource Player}}" Checked="CheckBoxAlwaysShowNotifyIcon_IsCheckedChanged" Unchecked="CheckBoxAlwaysShowNotifyIcon_IsCheckedChanged" Content="{x:Static resx:Resources.CheckBoxAlwaysShowNotifyIcon}" />
			<Grid>
				<Grid.RowDefinitions>
					<RowDefinition/>
					<RowDefinition/>
					<RowDefinition/>
				</Grid.RowDefinitions>
                <RadioButton Margin="0,2" x:Name="RadioButtonSlideCoverWhenMouseMove" Content="{x:Static resx:Resources.RadioButtonSlideCoverWhenMouseMove}" IsChecked="{Binding Settings.SlideCoverWhenMouseMove, Mode=TwoWay, Source={StaticResource Player}}" VerticalAlignment="Center"/>
                <CheckBox x:Name="CheckBoxOpenAlbumInfoWhenClickCover" Grid.Row="1" Content="{x:Static resx:Resources.CheckBoxOpenAlbumInfoWhenClickCover}" IsChecked="{Binding Settings.OpenAlbumInfoWhenClickCover, Mode=TwoWay, Source={StaticResource Player}}" IsEnabled="{Binding IsChecked, ElementName=RadioButtonSlideCoverWhenMouseMove}" VerticalAlignment="Center" Margin="20,2,2,3"/>
                <RadioButton Margin="0,2" Grid.Row="2" IsChecked="{Binding Settings.SlideCoverWhenMouseMove, Converter={StaticResource BoolReverseConverter}, Mode=TwoWay, Source={StaticResource Player}}" x:Name="RadioButtonSlideCoverWhenClick" Content="{x:Static resx:Resources.RadioButtonSlideCoverWhenClick}" VerticalAlignment="Center"/>
			</Grid>
            <Grid>
                <Grid.RowDefinitions>
                    <RowDefinition/>
                    <RowDefinition Height="5"/>
                    <RowDefinition/>
                </Grid.RowDefinitions>
                <Grid.ColumnDefinitions>
                    <ColumnDefinition Width="Auto"/>
                    <ColumnDefinition/>
                    <ColumnDefinition Width="Auto"/>
                </Grid.ColumnDefinitions>
                <TextBlock VerticalAlignment="Center" Text="{x:Static resx:Resources.UISettingsWindowMainInterfaceScaleTextBlock}" Margin="0,0,5,0"/>
                <Slider Grid.Column="1" Value="{Binding Settings.ScaleTransform, Source={StaticResource Player}, Mode=TwoWay}" Minimum="0.5" Maximum="1.5" SmallChange="0.01" LargeChange="0.1" Margin="0,0,5,0" ValueChanged="Slider_ValueChanged" />
                <Button Grid.Column="2" x:Name="BtnScaleTransformReset" Click="BtnScaleTransformReset_Click" Padding="5,0" Content="{x:Static resx:Resources.BtnScaleTransformReset}"/>
                <TextBlock Grid.Row="2" VerticalAlignment="Center" Text="{x:Static resx:Resources.UISettingsWindowMainInterfaceFontTextBlock}"/>
                <local:FontPicker Grid.Row="2" Grid.Column="1" Grid.ColumnSpan="2" Font="{Binding Settings.MainWindowFont, Source={StaticResource Player}}" Height="24"/>
            </Grid>
			<GroupBox Header="{x:Static resx:Resources.UISettingsWindowWindowBackgroundGB}" Margin="0,2">
				<Grid>
					<Grid.ColumnDefinitions>
						<ColumnDefinition Width="120"/>
						<ColumnDefinition/>
					</Grid.ColumnDefinitions>
					<Grid.RowDefinitions>
						<RowDefinition/>
                        <RowDefinition/>
                        <RowDefinition/>
                    </Grid.RowDefinitions>
                    <TextBlock VerticalAlignment="Center" Margin="5,0" Text="{x:Static resx:Resources.LyricsSettingsWindowTransparencyTB}"/>
					<Slider Grid.Column="1" Value="{Binding Settings.BackgroundTransparency, Source={StaticResource Player}}" Minimum="0" Maximum="0.99" LargeChange="0.1" SmallChange="0.01"/>
                    <CheckBox Grid.Row="1" Grid.ColumnSpan="2" VerticalAlignment="Center" IsChecked="{Binding Settings.AutoBackground, Source={StaticResource Player}, Converter={StaticResource BoolReverseConverter}}" Margin="0,5" Content="{x:Static resx:Resources.UISettingsWindowWindowManualColorCB}"/>
                    <local:PopupableColorPicker Grid.Row="2" Grid.ColumnSpan="2" Margin="0,5" Height="24" Color="{Binding Settings.Background, Source={StaticResource Player}}" Background="{Binding Background, ElementName=Window}" IsAlphaEnabled="False" IsEnabled="{Binding Settings.AutoBackground, Source={StaticResource Player}, Converter={StaticResource BoolReverseConverter}}"/>
				</Grid>
			</GroupBox>
			<GroupBox Margin="0,2">
				<GroupBox.Header>
                    <CheckBox IsChecked="{Binding Settings.ShowSpectrum, Source={StaticResource Player}}" Content="{x:Static resx:Resources.UISettingsWindowWindowSpectrumCB}"/>
				</GroupBox.Header>
				<StackPanel>
                    <Label FontSize="11" Content="{x:Static resx:Resources.LyricsSettingsWindowOccupyCPULabel}" />
					<Grid IsEnabled="{Binding Settings.ShowSpectrum, Source={StaticResource Player}}">
						<Grid.ColumnDefinitions>
							<ColumnDefinition Width="120"/>
							<ColumnDefinition/>
						</Grid.ColumnDefinitions>
						<Grid.RowDefinitions>
							<RowDefinition/>
							<RowDefinition/>
						</Grid.RowDefinitions>
                        <TextBlock VerticalAlignment="Center" Margin="5,0" Text="{x:Static resx:Resources.LyricsSettingsWindowTransparencyTB}"/>
						<Slider Grid.Column="1" Value="{Binding Settings.SpectrumTransparency, Source={StaticResource Player}}" Minimum="0" Maximum="1" LargeChange="0.1" SmallChange="0.01" Margin="0,2"/>
                        <TextBlock Grid.Row="1" VerticalAlignment="Center" Margin="5,0" Text="{x:Static resx:Resources.LyricsSettingsWindowColorGB}"/>
						<local:PopupableColorPicker Grid.Row="1" Grid.Column="1" Margin="0,2" Height="24" Color="{Binding Settings.SpectrumColor, Source={StaticResource Player}}" Background="{Binding Background, ElementName=Window}" IsAlphaEnabled="False"/>
					</Grid>
				</StackPanel>
			</GroupBox>
		</StackPanel>
	</Grid>
</local:ChildWindowBase>
